var app = getApp();

Page(Object.assign({},{
    data:{
        inited : false,
		siteroot : app.siteInfo.siteroot.replace('app/index.php', ''),uniacid: app.siteInfo.uniacid,
    },
    onLoad:function(options){
        var self = this;
        wx.setNavigationBarTitle({
          title: '签到',
        });
        app.com.auth(function(user){
            app.com.http('admin','POST',{op:'sign',signid:options.scene},0,false,'','',function(res){
                if (!res.data.errno && res.data ) {
                    self.setData({
                        sign : res.data.data,
                        inited : true,
                    })
                }
            });
        })
    },
    onPullDownRefresh: function () {
        wx.stopPullDownRefresh();
    },
    location : function( e ){
        app.com.location( e );
    },
    otherapp : function( e ){
        app.com.otherapp( e );
    },
    navigateto : function( e ){
        app.com.navigateto( e );
    },
    redirectto : function( e ){
        app.com.redirectto( e );
    },    
    callphone : function(e){
        app.com.callphone( e );
    },
    footNavigate(e){
        var url = e.currentTarget.dataset.url;
        wx.switchTab({
          url: url
        })
    }

}))